//
//  TUIConversationHelper.h
//  PeachDoctor
//
//  Created by ui on 2019/10/7.
//  Copyright © 2019 四川睡呗科技有限公司. All rights reserved.
//

#import <Foundation/Foundation.h>
@class TIMMessage;
@class PeachConversationModel;
@class TIMConversation;
NS_ASSUME_NONNULL_BEGIN

typedef void (^resultBlock)(NSArray<PeachConversationModel *> *result);//给block重命名,方便调用

@interface PeachConversationHelper : NSObject

@property (nonatomic, copy) resultBlock resultBlock;

/// 获取会话列表
/// @param block <#block description#>
- (void)fetchConversationsParam:(NSDictionary *)params
                         result:(void (^)(NSArray<PeachConversationModel *> * _Nonnull))block;
/// 获取最新会话列表
/// @param block <#block description#>
- (void)fetchNewlyIncreasedConversationParam:(NSDictionary *)params
                                      result:(void (^)(NSArray<PeachConversationModel *> * _Nonnull))block;

/// 监听腾讯IM会话列表刷新
/// @param conversations <#conversations description#>
/// @param block <#block description#>
- (void)onRefreshTIMConversation:(NSArray<TIMConversation *> *)conversations
                           block:(void (^)(NSMutableArray<PeachConversationModel *> * _Nonnull result))block;
@end

NS_ASSUME_NONNULL_END
